
<template>
  <div class="page-content">
    <div>
      <h2>程序员开发小助手</h2>
    </div>
    <div>
      <h3>快捷键</h3>
      <p>全局呼出快捷键：ctrl+alt+k</p>
    </div>
    <div>
      <h3>版本</h3>
      <p>版本号: 0.5.0</p>
      <p>时间: 2019-09-26 19:01</p>
    </div>
<div>
      <h3>其他介绍</h3>
      <p>音乐播放自动读取 user/Music 下的文件</p>
    </div>
    <!-- OS: Linux x64 4.15.0-64-generic -->
  </div>
</template>

<script>
import { ipcRenderer } from "electron";
import { constants } from "fs";
import { js_beautify } from "js-beautify";
import translateDb from "../../datastore/translate";

import md5 from "js-md5";
console.log(md5);
import { P_A_C_K_E_R, Urlencoded, MyObfuscate } from "../../publicjs/index";
console.log(P_A_C_K_E_R);

import { debug, debuglog } from "util";
export default {
  name: "note-page",
  data() {
    return {
      check_nav: 0,
      check_tab: 0,
      window_max: 0,
      datetime: "",
      timestamp: "",
      new_timetodate: "",
      difference: "",
      diffdate: "",
      inputjs: "",
      outputjs: "",
      input_translate: "",
      output_translate: "",
      history_translate: {}, //历史翻译
      in_undertoline: "",
      out_undertoline: "",
      in_linetounder: "",
      out_linetounder: "",
      in_toupper: "",
      out_toupper: "",
      in_tolower: "",
      out_tolower: ""
    };
  },
  created: function() {
    //监听主进程发来的消息
    this.$electron.ipcRenderer.on("main-process-messages", (event, arg) => {
      if (arg == "show_window") {
        this.check_tab = 0;
        //加一点延时防止切换未完成找不到dom的情况
        setTimeout(() => {
          this.$refs.translate_focus.focus();
        }, 10);
      }
      console.log(arg);
    });
    // `this` 指向 vm 实例
    console.log("a is: " + this.a);
  },

  methods: {
   
  }
};
</script>
